#include <functions\core_macros.h>
if (isServer) then {
	GVAR(AVAILABLE_DRONES) = TYR_Drone_Quantity;
	publicVariable QGVAR(AVAILABLE_DRONES);
};
if (!isDedicated && hasInterface) then {
	if (isNil "TYR_MENU_IsActive" || {TYR_MENU_IsActive <= 0}) then {
		["player", [mso_interaction_key], -9406, ["tmf\support\modules\tyr_drones\fn_menuDef.sqf", "main"]] call CBA_ui_fnc_add;
		[localize "STR_TYR_DRN_MENU_RADIO","if(if (!isnil 'mp_rights_fnc_hasRoles') then { [(getPlayerUID player),['leader','admin','drone']] call mp_rights_fnc_hasRoles} else { true }) then {createDialog ""TYR_DRN_drone_ui""}"] call mso_core_fnc_updateMenu;
	} else {
		if (!isnil "tyr_fnc_addHandler") then {
			["TYRMENU",
				[[
					localize "STR_TYR_DRN_MENU_RADIO"
					,{if (!isnil "mp_rights_fnc_hasRoles") then { [(getPlayerUID player),['leader','admin','drone']] call mp_rights_fnc_hasRoles} else { true }}
					,{createDialog "TYR_DRN_drone_ui"}
					,"tmf\support\modules\tyr_drones\drone.paa"
				]]
			] call tyr_fnc_addHandler;
		};
	};
};